using System;
using System.Collections.Generic;
using System.Web.Configuration;

using OpenWaves.EPiServer.AdminTools.LogViewer;

namespace OpenWaves.EPiServer
{
    public class OpenWavesEPiServerConfiguration : ILogViewerPluginConfiguration
    {
        private static OpenWavesEPiServerConfigurationSection ConfigSection
        {
            get
            {
                return WebConfigurationManager.GetSection("openwaves.episerver") as OpenWavesEPiServerConfigurationSection 
                       ?? new OpenWavesEPiServerConfigurationSection();
            }
        }
        public IEnumerable<string> LogDirectories
        {
            get { return ConfigSection.LogDirectories.Split(new[] {';'}, StringSplitOptions.RemoveEmptyEntries); }
        }
    }
}